<template>
  <view class="container">
    <view class="header">
      <view class="avatar-box">
        <image class="avatar" src="/static/default-avatar.png"></image>
      </view>
      <view class="user-info">
        <text class="nickname">用户名</text>
        <text class="user-id">用户ID: 10001</text>
      </view>
    </view>

    <view class="menu-list">
      <view class="menu-item">
        <view class="menu-item-left">
          <text class="menu-icon">👤</text>
          <text class="menu-text">个人信息</text>
        </view>
        <text class="menu-arrow">></text>
      </view>

      <view class="menu-item">
        <view class="menu-item-left">
          <text class="menu-icon">⚙️</text>
          <text class="menu-text">系统设置</text>
        </view>
        <text class="menu-arrow">></text>
      </view>

      <view class="menu-item">
        <view class="menu-item-left">
          <text class="menu-icon">📞</text>
          <text class="menu-text">联系我们</text>
        </view>
        <text class="menu-arrow">></text>
      </view>

      <view class="menu-item">
        <view class="menu-item-left">
          <text class="menu-icon">🔔</text>
          <text class="menu-text">关于应用</text>
        </view>
        <text class="menu-arrow">></text>
      </view>
    </view>

    <view class="logout-btn-container">
      <button class="logout-btn">退出登录</button>
    </view>
  </view>
</template>

<script>
export default {
  data() {
    return {
      userInfo: {
        nickname: "用户名",
        userId: "10001",
      },
    };
  },
  methods: {},
};
</script>

<style lang="scss">
.container {
  padding: 20px;

  .header {
    display: flex;
    align-items: center;
    padding: 30px 10px;
    margin-top: 30px;

    .avatar-box {
      width: 80px;
      height: 80px;
      border-radius: 50%;
      overflow: hidden;
      margin-right: 20px;

      .avatar {
        width: 100%;
        height: 100%;
      }
    }

    .user-info {
      display: flex;
      flex-direction: column;

      .nickname {
        font-size: 18px;
        font-weight: bold;
        margin-bottom: 10px;
      }

      .user-id {
        font-size: 14px;
        color: #666;
      }
    }
  }

  .menu-list {
    margin-top: 30px;
    background-color: #fff;
    border-radius: 10px;
    overflow: hidden;

    .menu-item {
      display: flex;
      justify-content: space-between;
      align-items: center;
      padding: 15px;
      border-bottom: 1px solid #f5f5f5;

      &:last-child {
        border-bottom: none;
      }

      .menu-item-left {
        display: flex;
        align-items: center;

        .menu-icon {
          margin-right: 10px;
          font-size: 20px;
        }

        .menu-text {
          font-size: 16px;
        }
      }

      .menu-arrow {
        color: #ccc;
      }
    }
  }

  .logout-btn-container {
    margin-top: 50px;
    padding: 0 20px;

    .logout-btn {
      background-color: #ff4d4f;
      color: #fff;
      border-radius: 5px;
      height: 44px;
      line-height: 44px;
    }
  }
}
</style>
